home *** CD-ROM | disk | FTP | other *** search
Text File | 1986-09-20 | 717 b | 32 lines | [TEXT/ttxt] |
- \ alert support
- \ 1/01/85 cbd Version 1
- \ 9/05/85 cdn Added disp: method
- \ 8/22/86 cdn Renumbered alert types to correspond with IM
-
- :CLASS Alert <Super X-Array
-
- Int resID
- Int Type \ 0=stop 1=note, 2=caution
-
- \ ( -- ) display the alert and execute the item
- :M SHOW: word0 int: resID 0 get: type
- CASE
- 0 OF call StopAlert ENDOF
- 1 OF call NoteAlert ENDOF
- 2 OF call CautionAlert ENDOF
- drop call Alert 0
- ENDCASE
- i->l dup 0>
- IF 1- exec: super
- ELSE drop
- THEN
- ;M
-
- \ ( resID type -- ) Associates object with it's resource
- :M INIT: put: type put: resid ;M
-
- \ ( resID type -- ) Combined actions of init: & show:
- :M DISP: init: self show: self ;M
-
- ;CLASS
-